<?php defined('SYSPATH') OR die('No direct access allowed.'); ?>

<div class="box" style="text-align: left;">
<form action="<?=url::base()?>index.php/product/product/insert" enctype="multipart/form-data" method="post">
	<table width="100%" >
		<tr height="30px;" >
			<td width="200px" align="right">ชื่อสินค้า  : </td>
			<td width="250px;" align="left"><input style="width: 100%;" type="text" name="name" maxlength="255"></td>
			<td></td>
		</tr>
		<tr height="30px;" valign="top">
			<td width="200px" align="right">รายละเอียด  : </td>
			<td width="250px;" align="left"><textarea style="width: 100%;" rows="5"  name="description"  ></textarea></td>
			<td></td>
		</tr>
		<tr height="30px;" >
			<td width="200px" align="right">ราคา  : </td>
			<td width="250px;" align="left"><input style="width: 200px;" type="text" name="price" maxlength="50"> บาท</td>
			<td></td>
		</tr>
		<tr height="30px;" >
			<td width="200px" align="right">รูปที่ 1 : </td>
			<td width="250px;" align="left">
			<select name="category_id" style="width: 150px;">
				<?php
				foreach ( $categorys as $obj) {
					echo "<option value=\"$obj->id\">$obj->name</option>";
				}?>
				</select>
			</td>
			<td></td>
		</tr>
		<tr height="30px;" >
			<td width="200px" align="right">รูปที่ 1 : </td>
			<td width="250px;" align="left"><input type="file" name="picture1" id="picture1" style="width: 200px;"></td>
			<td></td>
		</tr>
		<tr height="30px;" >
			<td width="200px" align="right">รูปที่ 2 : </td>
			<td width="250px;" align="left"><input type="file" name="picture2" id="picture2" style="width: 200px;"></td>
			<td></td>
		</tr>
		<tr height="30px;" >
			<td width="200px" align="right">รูปที่ 3 : </td>
			<td width="250px;" align="left"><input type="file" name="picture3" id="picture3" style="width: 200px;"></td>
			<td></td>
		</tr>
		<tr height="80px;" valign="middle">
			<td width="200px" align="right"></td>
			<td width="250px;" align="left">
				<input type="submit" style="width: 110px;height: 30px;" name="submit" value="ตกลง">
				<input type="reset" style="width: 110px;height: 30px;" name="reset" value="ยกเลิก">
			</td>
			<td></td>
		</tr>
	</table>
	
</form>
</div>
